var mongoose = require("mongoose");
mongoose.connect('mongodb://10.222.29.150:27017/amc_m');
var conn = mongoose.connection;
//db 连接处理
conn.on('connected', function () {
    console.log('connect success');
});
conn.on('error', function (err) {
    console.log('connect error ' + err);
});
conn.on('disconnected', function () {
    console.log('mongodb disconnected');
});

var merchantSchema = mongoose.Schema({
    merchant_name:String,
    password:String,
    address:String,
    imageUrl:String,
    idCardUrl:String
});
exports.merchant=mongoose.model('merchant',merchantSchema);